
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>一号店</title>
<link href="<?php echo $this->_var['shop_css_path']; ?>css/main.css" rel="stylesheet" type="text/css" />
<!--[if IE 6]>
<link href="<?php echo $this->_var['shop_css_path']; ?>css/main.ie6.css" rel="stylesheet" type="text/css" />
<![endif]-->
<!--[if IE 7]>
<link href="<?php echo $this->_var['shop_css_path']; ?>css/main.ie7.css" rel="stylesheet" type="text/css" />
<![endif]-->
<script type="text/javascript" src="<?php echo $this->_var['shop_css_path']; ?>js/jquery-1.5.1.min.js"></script>
<script type="text/javascript" src="<?php echo $this->_var['shop_css_path']; ?>js/jquery-imgslideshow.js"></script>
<script type="text/javascript" src="<?php echo $this->_var['shop_css_path']; ?>js/ks-switch.js"></script>
<script type="text/javascript" src="<?php echo $this->_var['shop_css_path']; ?>js/lib.js"></script>
<script type="text/javascript">
var timeout = 500;
var closetimer  = 0;
var ddmenuitem  = 0;

$(document).ready(function(){
    $('.cat_item').mousemove(function(){
    $(this).addClass('cat_item_on');
  });
  $('.cat_item').mouseleave(function(){
    $(this).removeClass('cat_item_on');
  });
  $('#slideshow').imgSlideShow({itemclass: 'i'})
  $("#slide-qg").switchTab({titCell: "dt a", trigger: "mouseover", delayTime: 0});
  $("#s_cart_nums1").hover(function(){
    mcancelclosetime();
    if(ddmenuitem) ddmenuitem.hide();
    ddmenuitem = $(document).find("#s_cartbox");
    ddmenuitem.fadeIn();
  },function(){
    mclosetime();
  });
  $("#s_cart_nums2").hover(function(){
    mcancelclosetime();
    if(ddmenuitem) ddmenuitem.hide();
    ddmenuitem = $(document).find("#s_cartbox");
    ddmenuitem.fadeIn();
  },function(){
    mclosetime();
  });
  $("#s_cartbox").hover(function(){
    mcancelclosetime();
  },function(){
    mclosetime();
  });
   var $cur = 1;
    var $i = 4;
    var $len = $('.hot_list>ul>li').length;
    var $pages = Math.ceil($len / $i);
    var $w = $('.hotp').width()-66;

    var $showbox = $('.hot_list');

    var $pre = $('div.left_icon');
    var $next = $('div.rgt_icon');

    $pre.click(function(){
        if (!$showbox.is(':animated')) {
            if ($cur == 1) {
                $showbox.animate({
                    left: '-=' + $w * ($pages - 1)
                }, 500);
                $cur = $pages;
            }
            else {
                $showbox.animate({
                    left: '+=' + $w
                }, 500);
                $cur--;
            }

        }
    });

    $next.click(function(){
        if (!$showbox.is(':animated')) {
            if ($cur == $pages) {
                $showbox.animate({
                    left: 0
                }, 500);
                $cur = 1;
            }
            else {
                $showbox.animate({
                    left: '-=' + $w
                }, 500);
                $cur++;
            }

        }
    });

});
function mclose()
{
  if(ddmenuitem) ddmenuitem.hide();
}
function mclosetime()
{
  closetimer = window.setTimeout(mclose, timeout);
}
function mcancelclosetime()
{
  if(closetimer)
  {
    window.clearTimeout(closetimer);
    closetimer = null;
  }
}
</script>
</head>

<body>
<div id="doc">
  <div id="s_hdw">

    <div id="s_tbar">
      <div class="s_hd">
        <!-- <div class="tbar_lft">您好，欢迎来到一号店！<a href="#">请登录</a> | <a href="#">免费注册</a></div> -->
       <?php 
$k = array (
  'name' => 'member_info',
);
echo $this->_echash . $k['name'] . '|' . serialize($k) . $this->_echash;
?>
        <div class="tbar_rgt">
          <ul>
            <li class="first"><a href="#">我的订单</a></li>
            <li><a href="#">我的一号店</a></li>
            <li><a href="#">帮助中心</a></li>
            <li><a href="#">联系客服</a></li>
            <li><a href="#">加入收藏</a></li>
            <li class="s_tel_str">服务热线：</li>
            <li class="s_tel">400-8823-823</li>
          </ul>
        </div>
      </div>
    </div>

    <div class="s_hd nav">
      <div id="s_logo"><a href="#"><img src="<?php echo $this->_var['shop_css_path']; ?>images/logo.jpg" border="0" /></a></div>
      <div id="s_nav">
        <ul>

        
          <li class="first <?php if ($this->_var['navigator_list']['config']['index'] == 1): ?> cur<?php endif; ?>"><a href="index.php"><?php echo $this->_var['lang']['home']; ?></a><span></span></li>
        
         <?php $_from = $this->_var['navigator_list']['middle']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }; $this->push_vars('', 'nav');$this->_foreach['nav_middle_list'] = array('total' => count($_from), 'iteration' => 0);
if ($this->_foreach['nav_middle_list']['total'] > 0):
    foreach ($_from AS $this->_var['nav']):
        $this->_foreach['nav_middle_list']['iteration']++;
?>
          <li <?php if ($this->_var['nav']['active'] == 1): ?> class="cur"<?php endif; ?>><a href="<?php echo $this->_var['nav']['url']; ?>"><?php echo $this->_var['nav']['name']; ?></a><span></span></li>
        <?php endforeach; endif; unset($_from); ?><?php $this->pop_vars();; ?>
<!--           <li><a href="#">抢购</a><span></span></li>
<li class="last"><a href="#">礼品</a><span></span></li> -->
        </ul>
      </div>
    </div>

    <div class="mmenu">
      <div class="s_hd">
      
        <div id="s_search">
          <form name="searchForm" method="get" action="search.php">
          <input name="keywords" type="text" id="keyword" value="<?php echo htmlspecialchars($this->_var['search_keywords']); ?>" class="search-input" />
          <input name="imageField" type="image" src="<?php echo $this->_var['shop_css_path']; ?>images/btn_search.jpg" /></form>
        </div>

        <div id="s_keyword">
        
         <?php if ($this->_var['searchkeywords']): ?>
          <ul>
            <li><strong><?php echo $this->_var['lang']['hot_search']; ?>：</strong></li>
           <?php $_from = $this->_var['searchkeywords']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }; $this->push_vars('', 'val');if (count($_from)):
    foreach ($_from AS $this->_var['val']):
?>
            <li><a href="search.php?keywords=<?php echo urlencode($this->_var['val']); ?>"><?php echo $this->_var['val']; ?></a></li>
           <?php endforeach; endif; unset($_from); ?><?php $this->pop_vars();; ?>
          </ul>
         <?php endif; ?>
        </div>

        <div id="s_cart">
          <ul>
            <li class="nums"><a href="" id="s_cart_nums1">购物车： <span>0</span>  件</a> <a href="" class="btn" id="s_cart_nums2"></a></li>
            <li class="checkout"><a href="#">去结算>></a></li>
          </ul>
        </div>

        <div id="s_cartbox" class="s_cartbox">您的购物车中暂无商品，赶快选择心爱的商品吧！</div>

        <div id="s_cats">
          <div class="cat_hd"><h3><a href="#">所有商品分类</a></h3></div>

          <!-- 通过php保留变量<?php echo $this->_var['smarty']; ?>访问几个环境和请求变量
            basename：返回路径中文件名部分
            dirname:返回路径中目录部分
          -->
          
          <div class="cat_bd"<?php if (basename ( $_SERVER['SCRIPT_FILENAME'] ) == 'index.php'): ?>  style="display:block" <?php endif; ?>>
          <ul>

           <?php $_from = $this->_var['categories']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }; $this->push_vars('', 'cat');if (count($_from)):
    foreach ($_from AS $this->_var['cat']):
?>
          <li class="cat_item">
            <h4 class="cat_tit"><a href="<?php echo $this->_var['cat']['url']; ?>" class="cat_tit_link"><?php echo htmlspecialchars($this->_var['cat']['name']); ?></a><span class="s_arrow">></span></h4>
            <div class="cat_cont">
              <div class="cat_cont_lft">
              <dl class="cf">
                <dd>
                  <ul>
                   <?php $_from = $this->_var['cat']['cat_id']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }; $this->push_vars('', 'child');if (count($_from)):
    foreach ($_from AS $this->_var['child']):
?>
                    <li class="first"><a href="<?php echo $this->_var['child']['url']; ?>"><?php echo htmlspecialchars($this->_var['child']['name']); ?></a></li>
                    <?php endforeach; endif; unset($_from); ?><?php $this->pop_vars();; ?>
                    <li><a href="#" class="more">更多</a></li>
                  </ul>
                </dd>

              </dl>
             <?php endforeach; endif; unset($_from); ?><?php $this->pop_vars();; ?>

            </div>
<!--
            <div class="cat_cont_rgt">
              <dl>
                <dt>推荐品牌</dt>
                <dd>
                  <ul>
                    <li><a href="#">奥利奥</a></li>
                    <li><a href="#">光明</a></li>
                    <li><a href="#">金龙鱼</a></li>
                    <li><a href="#">立顿</a></li>
                    <li><a href="#">咏萄 Everwines</a></li>
                    <li><a href="#">阿明</a></li>
                    <li><a href="#">康师傅</a></li>
                    <li><a href="#">蒙牛</a></li>
                    <li><a href="#">伊利</a></li>
                    <li><a href="#">可口可乐</a></li>
                    <li><a href="#">雀巢</a></li>
                    <li><a href="#">统一</a></li>
                    <li><a href="#">福临门</a></li>
                  </ul>
                </dd>
              </dl>

              <dl>
                <dt>促销专题</dt>
                <dd>
                  <ul>
                    <li><a href="#">饼干糕点10.8元任选3</a></li>
                    <li><a href="#">阳澄湖大闸蟹立省百元</a></li>
                    <li><a href="#">清新水果季 全场上海</a></li>
                  </ul>
                </dd>
              </dl>
            </div> -->
          </div>
        </li>

        <!--   </ul> -->
          <!--<div class="all_cats"><a href="#" class="more">全部商品分类</a></div>-->
          </div>
        </div>
      </div>
    </div>

  </div>